﻿@using VirtualPress.Infrastructure.Entities.Entity;
@{
    Meeting meeting = ViewBag.Meeting;
    ViewBag.Title = "期刊设置 -- " + meeting.Name;
    Layout = "/Areas/WorkSpace/Views/Shared/_WorkSpace.cshtml";
}
<div id="content-header">
    <h1>
        期刊设置</h1>
</div>
<div id="breadcrumb">
    <a href="/WorkSpace/Home" class="tip-bottom"><i class="icon-home"></i>起始页</a> <a
        href="/WorkSpace/console/baseinfo">期刊管理</a> 
        <a class="current">期刊设置</a>
</div>
<div class="container-fluid">
    <div class="row-fluid">
        <div class="span12">
            <div class="widget-box">
                <div class="widget-title">
                    <span class="icon"><i class="icon-pencil"></i></span>
                    <h5>
                        稿件模板</h5>
                    <h5 style="float:right;color:Red;"></h5>
                </div>
                <div class="widget-content nopadding">
                    <form id="form-wizard" class="form-horizontal" method="post" enctype="multipart/form-data" 
                        action="/WorkSpace/meeting/Settings">
                    <input type="hidden" name="meeting" value="@meeting.Id" />
                    <div id="form-wizard-1" class="step">
                        <div class="control-group">
                            <label class="control-label">
                                默认审回时间 (天)  </label>
                            <div class="controls">
                                <input name="DefaultExamineDay" class="{required:true,digits:true}" type="text" value="@meeting.DefaultExamineDay" />
                            </div>
                        </div>
                        <div class="control-group">
                            <label class="control-label">
                                稿件基准页数  </label>
                            <div class="controls">
                                <input name="ManuscriptPageSize" class="{required:true,digits:true}" type="text" value="@meeting.ManuscriptPageSize" />
                            </div>
                        </div>
                         <div class="control-group">
                            <label class="control-label">
                                是否收取专审费用
                            </label>
                            <div class="controls">
                                <select id="sltIsFeeForExpertExmaine" name="isFeeForExpertExmaine" onchange="changeFeeSet(this)">
                                    <option value="true" selected="selected" >收费</option>
                                    <option value="false">不收费</option>
                                </select>
                            </div>
                        </div>
                        <div class="control-group">
                            <label class="control-label">
                                基准专审费用  </label>
                            <div class="controls">
                                <input id="txtPagePrice" name="PagePrice" class="{required:true,digits:true}" type="text" value="@meeting.PagePrice" />
                            </div>
                        </div>
                        <div class="control-group">
                            <label class="control-label">
                                超页价格  </label>
                            <div class="controls">
                                <input name="PricePerPrice" class="{required:true,digits:true}" type="text" value="@meeting.PricePerPrice" /> <span>每超过1页价格</span>
                            </div>
                        </div>
                        <div class="control-group">
                            <label class="control-label">
                                基准出版版面费 </label>
                            <div class="controls">
                                <input name="PublicationPrice" class="{required:true,digits:true}" type="text" value="@meeting.PublicationPrice" />
                            </div>
                        </div>
                    </div>
                    <div class="form-actions">
                        <a class="btn btn-primary" href="/workspace/meeting/index">返回</a>
                        <input id="next" class="btn btn-primary" type="submit" value="保存" />
                    </div>
                    <div id="submitted">
                    </div>
                    </form>
                </div>
            </div>
        </div>
    </div>
</div>
@section tail
{ 
    <script type="text/javascript" src="/scripts/jquery.validate.js"></script>
    <script type="text/javascript" src="/scripts/unicorn.wizard.js"></script>
    <script type="text/javascript" src="/scripts/jquery.metadata.js"></script>
    <script type="text/javascript" src="/scripts/jquery.wizard.js"></script>
    <script type="text/javascript">
        $(function () {
            $('#likjournalmanage').addClass('open active');
            $('#sltIsFeeForExpertExmaine').val('@meeting.isFeeForExpertExmaine.ToString().ToLower()').trigger('change');
        });
        function changeFeeSet(sender) {
            var val = $(sender).val();
            if (/false/i.test(val)) {
                $('#txtPagePrice').attr('disabled', 'disabled');
            }
            else {
                $('#txtPagePrice').removeAttr('disabled', 'disabled');
            }
        }
    </script>
}
